# coding=utf8

# Copyright 2018 JDCLOUD.COM
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# NOTE: This class is auto generated by the jdcloud code generator program.


class HistorySql(object):

    def __init__(self, id=None, dataSourceId=None, sqlStr=None, user=None, status=None, createTime=None, spendTime=None, message=None, ip=None, dbName=None, endTime=None, exeStatus=None, sqlType=None):
        """
        :param id: (Optional) 主键id。
        :param dataSourceId: (Optional) 数据源id。
        :param sqlStr: (Optional) 执行sql内容。
        :param user: (Optional) 执行用户。
        :param status: (Optional) 数据状态。0：有效，1：无效
        :param createTime: (Optional) 创建时间，格式为：YYYY-MM-DD HH:mm:ss。
        :param spendTime: (Optional) 执行花费时间。
        :param message: (Optional) 执行消息。
        :param ip: (Optional) dms执行地址。
        :param dbName: (Optional) 数据库名称。
        :param endTime: (Optional) 执行结束时间，格式为：YYYY-MM-DD HH:mm:ss。
        :param exeStatus: (Optional) 执行结果，SUCCESS：成功，FAILED失败。
        :param sqlType: (Optional) sql类型, CREATE("CREATE", 0), ALTER_DATA("ALTER_DATA", 1), ALTER_STRUCT("ALTER_STRUCT", 2), DROP("DROP", 4), CONSOLE("CONSOLE", 5), BATCH_CREATE("BATCH_CREATE", 6), IMPORT_DATA("IMPORT_DATA", 7), EXPORT_STRUCT_DATA("EXPORT_STRUCT_DATA", 8);
        """

        self.id = id
        self.dataSourceId = dataSourceId
        self.sqlStr = sqlStr
        self.user = user
        self.status = status
        self.createTime = createTime
        self.spendTime = spendTime
        self.message = message
        self.ip = ip
        self.dbName = dbName
        self.endTime = endTime
        self.exeStatus = exeStatus
        self.sqlType = sqlType
